package top.iridescent;

import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

@Component
public class Schedule {

    private static int count = 0;

    @Scheduled(cron = "*/2 * * * * ?")
    public void test1() {
        count += 1;
        System.out.println("============================执行第 {" + count +"} 次===================");
    }
}
